using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._BusinessAnalystTools._TradeAreas
{
    /// <summary>
    /// <para>Remove Overlap </para>
    /// <para>Removes overlap between polygons contained in multiple input layers.</para>
    /// <para>移除多个输入图层中包含的面之间的重叠。</para>
    /// </summary>    
    [DisplayName("Remove Overlap ")]
    public class RemoveOverlapMultiple : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public RemoveOverlapMultiple()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_features">
        /// <para>Input Features</para>
        /// <para>The input features containing the overlapping polygons.</para>
        /// <para>包含重叠面的输入要素。</para>
        /// </param>
        /// <param name="_out_feature_class">
        /// <para>Output Feature Class</para>
        /// <para>The feature class containing the new trade area features.</para>
        /// <para>包含新贸易区要素的要素类。</para>
        /// </param>
        public RemoveOverlapMultiple(object _in_features, object _out_feature_class)
        {
            this._in_features = _in_features;
            this._out_feature_class = _out_feature_class;
        }
        public override string ToolboxName => "Business Analyst Tools";

        public override string ToolName => "Remove Overlap ";

        public override string CallName => "ba.RemoveOverlapMultiple";

        public override List<string> AcceptEnvironments => ["workspace"];

        public override object[] ParameterInfo => [_in_features, _out_feature_class, _method.GetGPValue(), _join_attributes.GetGPValue()];

        /// <summary>
        /// <para>Input Features</para>
        /// <para>The input features containing the overlapping polygons.</para>
        /// <para>包含重叠面的输入要素。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Features")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_features { get; set; }


        /// <summary>
        /// <para>Output Feature Class</para>
        /// <para>The feature class containing the new trade area features.</para>
        /// <para>包含新贸易区要素的要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Feature Class")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_feature_class { get; set; }


        /// <summary>
        /// <para>Method</para>
        /// <para><xdoc>
        ///   <para>Specifies how the overlap between trade areas will be removed.</para>
        ///   <bulletList>
        ///     <bullet_item>Center Line—Overlap will be removed by creating a border that evenly distributes the area of intersection between polygons. This is the default.</bullet_item><para/>
        ///     <bullet_item>Thiessen—Overlap will be removed using straight lines to divide the area of intersection.</bullet_item><para/>
        ///     <bullet_item>Grid—Overlap will be removed by creating a grid of parallel lines used to define a natural division between polygons.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定如何消除贸易区域之间的重叠。</para>
        ///   <bulletList>
        ///     <bullet_item>中心线 - 将通过创建均匀分布面之间相交区域的边界来移除重叠。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>泰森—将使用直线移除重叠以划分相交区域。</bullet_item><para/>
        ///     <bullet_item>格网 - 将通过创建平行线格网来移除重叠，该格网用于定义面之间的自然划分。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Method")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _method_value _method { get; set; } = _method_value._CENTER_LINE;

        public enum _method_value
        {
            /// <summary>
            /// <para>Center Line</para>
            /// <para>Center Line—Overlap will be removed by creating a border that evenly distributes the area of intersection between polygons. This is the default.</para>
            /// <para>中心线 - 将通过创建均匀分布面之间相交区域的边界来移除重叠。这是默认设置。</para>
            /// </summary>
            [Description("Center Line")]
            [GPEnumValue("CENTER_LINE")]
            _CENTER_LINE,

            /// <summary>
            /// <para>Thiessen</para>
            /// <para>Thiessen—Overlap will be removed using straight lines to divide the area of intersection.</para>
            /// <para>泰森—将使用直线移除重叠以划分相交区域。</para>
            /// </summary>
            [Description("Thiessen")]
            [GPEnumValue("THIESSEN")]
            _THIESSEN,

            /// <summary>
            /// <para>Grid</para>
            /// <para>Grid—Overlap will be removed by creating a grid of parallel lines used to define a natural division between polygons.</para>
            /// <para>格网 - 将通过创建平行线格网来移除重叠，该格网用于定义面之间的自然划分。</para>
            /// </summary>
            [Description("Grid")]
            [GPEnumValue("GRID")]
            _GRID,

        }

        /// <summary>
        /// <para>Attributes To Join</para>
        /// <para><xdoc>
        ///   <para>Specifies which attributes of input layers will be copied to the output.</para>
        ///   <bulletList>
        ///     <bullet_item>All attributes—All attributes from the input features will be transferred to the output feature class. This is the default.</bullet_item><para/>
        ///     <bullet_item>All attributes except feature IDs—All attributes from the input features, except the FID field, will be transferred to the output feature class.</bullet_item><para/>
        ///     <bullet_item>Only feature IDs—Only the FID field from the input features will be transferred to the output feature class.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将输入图层的哪些属性复制到输出中。</para>
        ///   <bulletList>
        ///     <bullet_item>所有属性—输入要素中的所有属性都将传输到输出要素类。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>除要素 ID 之外的所有属性—输入要素中的所有属性（FID 字段除外）都将传输到输出要素类。</bullet_item><para/>
        ///     <bullet_item>仅要素 ID - 仅将输入要素中的 FID 字段传输到输出要素类。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Attributes To Join")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _join_attributes_value _join_attributes { get; set; } = _join_attributes_value._ALL;

        public enum _join_attributes_value
        {
            /// <summary>
            /// <para>All attributes</para>
            /// <para>All attributes—All attributes from the input features will be transferred to the output feature class. This is the default.</para>
            /// <para>所有属性—输入要素中的所有属性都将传输到输出要素类。这是默认设置。</para>
            /// </summary>
            [Description("All attributes")]
            [GPEnumValue("ALL")]
            _ALL,

            /// <summary>
            /// <para>All attributes except feature IDs</para>
            /// <para>All attributes except feature IDs—All attributes from the input features, except the FID field, will be transferred to the output feature class.</para>
            /// <para>除要素 ID 之外的所有属性—输入要素中的所有属性（FID 字段除外）都将传输到输出要素类。</para>
            /// </summary>
            [Description("All attributes except feature IDs")]
            [GPEnumValue("NO_FID")]
            _NO_FID,

            /// <summary>
            /// <para>Only feature IDs</para>
            /// <para>Only feature IDs—Only the FID field from the input features will be transferred to the output feature class.</para>
            /// <para>仅要素 ID - 仅将输入要素中的 FID 字段传输到输出要素类。</para>
            /// </summary>
            [Description("Only feature IDs")]
            [GPEnumValue("ONLY_FID")]
            _ONLY_FID,

        }

        public RemoveOverlapMultiple SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}